import Vue from "vue";
import VueRouter from "vue-router";
Vue.use(VueRouter);
import HomePage from "@/page/Home/Home.vue";
import CompanyPage from "@/page/Company/Company.vue";
import EmployeePage from "@/page/Employee/Employee.vue";


const router = new VueRouter({
    mode: 'hash', // 使用 hash 模式
    routes: [
        {
            path: '/',
            name: 'home',
            component: HomePage,
            redirect: '/company',
            children: [
                {
                    path: '/company',
                    component: CompanyPage,
                    meta: { title: '公司管理' }
                },
                {
                    path: '/employee',
                    component: EmployeePage,
                    meta: { title: '员工管理' }
                }]
        },

    ]
});

export default router;
